const path = require('path');
const { merge } = require('webpack-merge')
const common = require('./webpack.common.js'); //引入公共配置


module.exports = merge(common, {
    mode: "development",
    devtool: "eval-cheap-module-source-map",
    devServer: { //开发服务器
        port: "9080",
        proxy: { //反向代理，根据需求自行修改
            "/api": {
                target: "http://127.0.0.1:1111",
                pathRewrite: {
                    "^/api": ""
                }
            },
        },
        open: true,  //打开浏览器
        // hot: 'only',//开启热更新功能
        // hot: false,
        client: false,
        // liveReload: false,
       },
    target: ["web"],
});
